Skip to content

Add support for OCaml. #4758

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 15, 2025
Merged

Add support for OCaml. #4758

merged 1 commit into from
May 15, 2025

Conversation

progoramur
Copy link
Contributor

I am signing Oracle Contributor Agreement.

This pull request adds support for OCaml.

Almost full support for OCaml syntax is provided including quoted string literals and extension nodes. The support for docstrings is not implemented. Also, primitive types are added to the list of keywords because most programmers do not use them as variable names (result is an exception).

Copy link

Thank you for your pull request and welcome to our community! To contribute, please sign the Oracle Contributor Agreement (OCA).
The following contributors of this PR have not signed the OCA:

To sign the OCA, please create an Oracle account and sign the OCA in Oracle's Contributor Agreement Application.

When signing the OCA, please provide your GitHub username. After signing the OCA and getting an OCA approval from Oracle, this PR will be automatically updated.

If you are an Oracle employee, please make sure that you are a member of the main Oracle GitHub organization, and your membership in this organization is public.

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Required At least one contributor does not have an approved Oracle Contributor Agreement. label Apr 15, 2025
Copy link

Thank you for signing the OCA.

@oracle-contributor-agreement oracle-contributor-agreement bot added OCA Verified All contributors have signed the Oracle Contributor Agreement. and removed OCA Required At least one contributor does not have an approved Oracle Contributor Agreement. labels Apr 15, 2025
Copy link
Member

@vladak vladak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in general this looks good, the copyright commens have to be addressed.

@vladak
Copy link
Member

vladak commented Apr 15, 2025

Also, it would be nice to supply a sample OCaml file + expected xref and add a test checking it, similarly to some other analyzers.

@progoramur
Copy link
Contributor Author

Also, it would be nice to supply a sample OCaml file + expected xref and add a test checking it, similarly to some other analyzers.

Will add within couple days.

Could you please give a good example?

@vladak
Copy link
Member

vladak commented Apr 15, 2025

Also, it would be nice to supply a sample OCaml file + expected xref and add a test checking it, similarly to some other analyzers.

Will add within couple days.

Could you please give a good example?

See the recently changed Fortran analyzer (PR #4642) for example.

@progoramur
Copy link
Contributor Author

@vladak thanks for the hints. Added tests, please take a look.

@vladak
Copy link
Member

vladak commented Apr 16, 2025

There is a pre-existing issue tracking the OCaml support (#4407), please add fixes #4407 to the commit comment.

@vladak
Copy link
Member

vladak commented Apr 16, 2025

Also, rebase.

@vladak
Copy link
Member

vladak commented Apr 16, 2025

I believe the newly introduced files do not have to have the Portions in the copyright.

@progoramur progoramur requested a review from vladak April 18, 2025 20:34
@progoramur
Copy link
Contributor Author

@vladak

Vladimir, from my point of view, all the comments seem to have been addressed. Would you please double check if the PR can be merged? Thank you very much for your hard work on OpenGrok.

@vladak vladak merged commit 445d2f6 into oracle:master May 15, 2025
10 checks passed
@vladak
Copy link
Member

vladak commented May 15, 2025

Looks good, sorry for the delay. Thanks for the contribution !

@progoramur progoramur deleted the ocaml branch May 15, 2025 16:25
@progoramur
Copy link
Contributor Author

Thank you so much for your review and hard work on this incredibly useful tool!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants